import { useThemeConfigStore } from "@renderer/store/modules/themeConfig";
const themeConfigStore: any = useThemeConfigStore();

let config = JSON.parse(JSON.stringify(themeConfigStore.globalTheme));

export const barStackCharts_staticData = {
  xAxis: [
    "1月",
    "2月",
    "3月",
    "4月",
    "5月",
    "6月",
    "7月",
    "8月",
    "9月",
    "10月",
    "11月",
    "12月",
  ],
  data: [
    {
      name: "data1",

      value: [110, 132, 101, 134, 90, 230, 210, 120, 132, 101, 134, 90],
    },
    {
      name: "data2",
      value: [120, 132, 101, 134, 230, 230, 210, 120, 132, 101, 134, 90],
    },
  ],
};
config.xAxis.data = barStackCharts_staticData.xAxis;
export const barStackCharts = {
  ...config,
  ifEcharts: true,
  series: [
    {
      name: barStackCharts_staticData.data[0].name,
      type: "bar",
      label: {
        show: true,
        position: "top",
        color: "#fff",
        fontSize: 22,
      },
      emphasis: {
        disabled: true,
        focus: "none",
      },
      stack: "total",
      barWidth: "25%",
      itemStyle: {
        color: "auto",
        borderRadius: 0,
        opacity: 1,
      },
      showBackground: false,
      backgroundStyle: {
        color: "rgba(180, 180, 180, 0.2)",
        borderRadius: 0,
        opacity: 1,
      },
      data: barStackCharts_staticData.data[0].value,
    },
    {
      name: barStackCharts_staticData.data[1].name,
      type: "bar",
      emphasis: {
        disabled: true,
        focus: "none",
      },
      stack: "total",
      label: {
        show: true,
        position: "top",
        color: "#fff",
        fontSize: 22,
      },
      barWidth: "25%",
      itemStyle: {
        color: "auto",
        borderRadius: 0,
        opacity: 1,
      },
      showBackground: false,
      backgroundStyle: {
        color: "rgba(180, 180, 180, 0.2)",
        borderRadius: 0,
        opacity: 1,
      },
      data: barStackCharts_staticData.data[1].value,
    },
  ],
};
